<template>
  <view class="setting-container">
    <MenuLayout>
      <mz-list>
        <mz-list-item
          v-for="(item) in menuList"
          :key="item.title"
          :title="item.title"
          :show-arrow="item.showArrow"
          :right-text="item.rightText"
          @click="goto(item)"
        ></mz-list-item>
      </mz-list>
    </MenuLayout>
  </view>
</template>

<script>
import MenuLayout from "../../components/public/MenuLayout/index.vue";
export default {
  components: {
    MenuLayout
  },
  data() {
    return {};
  },
  computed: {
    menuList() {
      return [
        {
          title: "打印机设置",
          url: "printer",
          showArrow: true
        }
      ];
    }
  },
  methods: {
    goto(item) {
      if (item.url) {
        this.$goto(item.url);
      } else if (item.fun) {
        item.fun();
      }
    }
  }
};
</script>

<style lang="scss">
.setting-container {
  padding-top: 30rpx;
}
</style>
